<?php
include('config.php');



function test($whatpath){
	return($whatpath);
	}

class profile{

	function printname($given_name, $sur_name){
		print "$given_name $sur_name<br />";
	}
	
	function printphoto($usernum){
		
		
		#$photopath = $image_path."/".$usernum.".jpg";
		#print $image_path;
		#print $image_path;
		print "<img src=\"http://backserv/pplimages/$usernum.jpg\" /><br />";
		
	}
	

	function printdept($deptnum){
		print "<a href=\"http://backserv/$local_dir?viewtype=$dept\">$deptnum</a><br />";
	}
	
	function printtitle($title){
		print "$title <br />";
	}
	
	function print_toolbar($usernum){
		$toolbar = "<span style=\"margin-right: 15px\"><a class=\"toolbar\" href=\"http://backserv/$local_dir/tobecontinued\">x</a></span>";
	    $toolbar = $toolbar."<span style=\"margin-right: 15px\"><a class=\"toolbar\" href=\"http://backserv/$local_dir/tobecontinued\">e</a></span>";
	}
	
	function profile($usernum, $deptnum, $given_name, $sur_name, $title){
		print "IP: $image_path<br />";
		print $this->printphoto($usernum);
		print $this->printname($given_name,$sur_name);
		print $this->printtitle($title);
		print $this->printdept($deptnum);
		# If admin's signed in, print the toolbar
		if(isset($_COOKIE['ppl'])){
			print $this->print_toolbar($usernum);
			}
			
	}
}

?>